package team.zero.lemon.common.date;

import java.util.Calendar;
import java.util.Date;
import java.util.TimeZone;

/**
 * Created by bolin on 2016/5/17.
 */
public class UTC {
    private UTC utcDate;

    public static Date date() {
        Calendar currentTime = Calendar.getInstance(TimeZone.getTimeZone("UTC"));
        currentTime.set(Calendar.ZONE_OFFSET, TimeZone.getTimeZone("UTC").getRawOffset());
        Calendar calendar = Calendar.getInstance();
        calendar.set(Calendar.HOUR_OF_DAY, currentTime.get(Calendar.HOUR_OF_DAY));
        Date utcDate = calendar.getTime();
        return utcDate;
    }
}
